import baseUrl from './base-url-config'

const { product: prefix } = baseUrl

export default {
  // 查询角色
  getRoleDataAPI: {
    url: `${prefix}/edc/sys/role/query`,
    method: 'GET',
  },
  // 创建角色
  createRoleDataAPI: {
    url: `${prefix}/edc/sys/role/create`,
    method: 'POST',
  },
  // 修改角色
  updateRoleDataAPI: {
    url: `${prefix}/edc/sys/role/update`,
    method: 'PUT',
  },
  // 删除角色
  deleteRoleDataAPI: {
    url: `${prefix}/edc/sys/role/delete`,
    method: 'DELETE',
  },
  // 获得角色拥有的菜单编号
  getMenuNumberAPI: {
    url: `${prefix}/edc/sys/role-menu/list-role-resources`,
    method: 'GET',
  },
  // 根据角色筛选菜单列表
  getListByRolerAPI: {
    url: `${prefix}/edc/sys/menu/listByRole`,
    method: 'GET',
  },
  // 赋予角色菜单
  assignRoleMenuAPI: {
    url: `${prefix}/edc/sys/role-menu/assign-role-menu`,
    method: 'POST',
  },
}
